package gossbs;

import java.util.Scanner;

public class J02MyAge {
	public static void main (String[] args){
		//1변수선언
		int birthYear;
		int currentYear;
		int age;
		Scanner sc = null;
		
		//2생년입력, 나이게산
		sc = new Scanner(System.in);
		System.out.println("생년을 입력하세요");
		birthYear = sc.nextInt();
		System.out.println("현재년도를 입력하세요");
		currentYear = sc.nextInt();
		
		age = currentYear - birthYear + 1;
		//3결과축력
		System.out.println(birthYear);
		System.out.println(currentYear);
		System.out.println(age);
		sc.close();
		
	}
}
